/**
 * 
 */
package com.yidu.erp.action.fdfinance;

import java.util.Map;

import javax.annotation.Resource;
import javax.servlet.http.HttpSession;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import com.yidu.common.Pages;
import com.yidu.erp.model.BeyondStaff;
import com.yidu.erp.service.beyondMoney.MoneyService;

/**
 * @author liao
 *
 */
@Controller
@RequestMapping("finance")
public class FinanceAaction {
	@Resource
	private MoneyService moneyService;
	/**
	 * 查询分店支出财务信息
	 * @param param 财务属性
	 * @param limit 每页数量
	 * @param page  页数
	 * @return
	 */
	@RequestMapping("/financeAjax")
	@ResponseBody
	public Map<String,Object> financeShow(@RequestParam Map<String, Object> param, int limit, int page,HttpSession session){
		BeyondStaff staff=(BeyondStaff) session.getAttribute("staff");
		param.put("annexId", staff.getAnnexId());
		Pages pages = new Pages();
		pages.setMaxResult(limit);
		pages.setCurPage(page);
		param.put("pages", pages);
		return  moneyService.AllFdcure(param);
	}
}
